<?php
// 确定配置键名，默认为'consulting_service'
$configKey = isset($configKey) ? $configKey : 'consulting_service';
// 咨询服务服务默认配置
$defaultConfig = [
    'section_id' => $configKey,
    'section_pretitle' => '专业服务',
    'section_title' => '咨询服务方案',
    'section_subtitle' => '我们提供定制化的专业咨询服务，帮助您解决业务挑战，实现增长目标',
    'bg_color' => 'white',
    'card_style' => 'modern', // modern, classic, minimal
    'services' => [
        [
            'id' => 'strategy',
            'title' => '战略规划咨询',
            'description' => '基于行业趋势和市场分析，为您制定切实可行的业务发展战略',
            'icon' => 'fa-line-chart',
            'accent_color' => 'blue-600',
            'features' => [
                '市场机会评估',
                '竞争格局分析',
                '增长战略制定',
                '业务模式优化',
                '长期发展规划'
            ],
            'case_count' => 120,
            'testimonial' => '通过战略咨询，我们明确了发展方向，季度业绩提升了35%',
            'client' => '某科技公司 CEO'
        ],
        [
            'id' => 'operation',
            'title' => '运营效率咨询',
            'description' => '优化内部流程，降低运营成本，提升组织整体效率和执行力',
            'icon' => 'fa-cogs',
            'accent_color' => 'green-600',
            'features' => [
                '流程梳理与优化',
                '资源配置分析',
                '成本控制方案',
                '绩效评估体系',
                '执行力提升计划'
            ],
            'case_count' => 95,
            'testimonial' => '运营流程优化后，我们的工作效率提升了40%，成本降低了18%',
            'client' => '某制造企业 运营总监'
        ],
        [
            'id' => 'digital',
            'title' => '数字化转型咨询',
            'description' => '制定数字化转型路线图，推动业务模式创新和技术落地',
            'icon' => 'fa-database',
            'accent_color' => 'purple-600',
            'features' => [
                '数字化成熟度评估',
                '技术选型建议',
                '数据战略规划',
                '转型路线图设计',
                '组织能力建设'
            ],
            'case_count' => 80,
            'testimonial' => '在咨询团队的帮助下，我们成功完成了数字化转型，客户满意度显著提升',
            'client' => '某零售企业 数字化负责人'
        ],
        [
            'id' => 'hr',
            'title' => '人力资源咨询',
            'description' => '构建高效人力资源体系，提升组织能力和人才竞争力',
            'icon' => 'fa-users',
            'accent_color' => 'orange-600',
            'features' => [
                '组织架构设计',
                '人才梯队建设',
                '薪酬体系优化',
                '绩效管理体系',
                '企业文化建设'
            ],
            'case_count' => 105,
            'testimonial' => '人力资源体系的优化帮助我们吸引并留住了核心人才，团队战斗力大幅提升',
            'client' => '某金融机构 人力资源总监'
        ]
    ],
    'process' => [
        [
            'step' => 1,
            'title' => '需求分析',
            'description' => '深入了解您的业务现状、挑战和目标，明确咨询需求和预期成果'
        ],
        [
            'step' => 2,
            'title' => '方案设计',
            'description' => '基于诊断结果，结合行业最佳实践，制定定制化咨询方案'
        ],
        [
            'step' => 3,
            'title' => '方案实施',
            'description' => '协助您的团队落地执行咨询方案，提供必要的培训和指导'
        ],
        [
            'step' => 4,
            'title' => '效果评估',
            'description' => '跟踪方案实施效果，进行成果评估，并提供持续优化建议'
        ]
    ],
    'pricing' => [
        [
            'id' => 'standard',
            'title' => '标准咨询包',
            'subtitle' => '适合小型企业基础需求',
            'price' => 29800,
            'period' => '项目',
            'features' => [
                '最多5次咨询会议',
                '基础分析报告',
                '1套解决方案',
                '1个月实施支持',
                '电子邮件后续服务'
            ],
            'recommended' => false
        ],
        [
            'id' => 'professional',
            'title' => '专业咨询包',
            'subtitle' => '适合成长型企业核心需求',
            'price' => 59800,
            'period' => '项目',
            'features' => [
                '最多12次咨询会议',
                '深度分析报告',
                '3套解决方案',
                '3个月实施支持',
                '电话+邮件后续服务',
                '1次中期评估'
            ],
            'recommended' => true
        ],
        [
            'id' => 'enterprise',
            'title' => '企业定制包',
            'subtitle' => '适合大型企业复杂需求',
            'price' => 128000,
            'period' => '起/项目',
            'features' => [
                '不限次数咨询会议',
                '定制化分析报告',
                '全套解决方案',
                '6个月实施支持',
                '专属顾问全程跟进',
                '季度评估与优化',
                '团队专项培训'
            ],
            'recommended' => false
        ]
    ],
    'cta' => [
        'title' => '准备好开始您的咨询项目了吗？',
        'subtitle' => '填写表单预约免费咨询评估，我们将在24小时内与您联系',
        'button_text' => '预约免费评估',
        'form_action' => '/submit-consulting.php'
    ],
    // 新增texts字段管理所有硬编码文本
    'texts' => [
        'process_section_title' => '我们的咨询流程',
        'process_section_subtitle' => '标准化的咨询流程确保服务质量，为您提供清晰的合作路径和可预期的成果',
        'pricing_section_title' => '咨询服务定价',
        'pricing_section_subtitle' => '灵活的定价方案满足不同规模企业的需求，所有服务均提供质量保证',
        'pricing_select_button' => '选择此方案',
        'pricing_custom_inquiry' => '需要更灵活的定制方案？',
        'pricing_contact_link_text' => '联系我们',
        'pricing_contact_suffix' => '获取专属报价',
        'experts_section_title' => '我们的咨询专家',
        'experts_section_subtitle' => '拥有平均10年以上行业经验的专家团队，为您提供专业的咨询服务',
        'case_count_label' => '已完成 {count}+ 成功案例',
        'form_required_mark' => '*',
        'form_company_placeholder' => '请输入您的公司名称',
        'form_contact_name_placeholder' => '请输入您的姓名',
        'form_phone_placeholder' => '请输入您的联系电话',
        'form_email_placeholder' => '请输入您的电子邮箱',
        'form_service_type_default' => '请选择服务类型',
        'form_service_type_multiple' => '多项服务组合',
        'form_service_type_other' => '其他服务需求',
        'form_message_placeholder' => '请简要描述您的咨询需求...',
        'form_feature_1_title' => '免费初步评估',
        'form_feature_1_desc' => '无需付费即可获取专业咨询建议',
        'form_feature_2_title' => '快速响应',
        'form_feature_2_desc' => '工作时间内24小时内响应您的咨询需求',
        'form_feature_3_title' => '信息保密',
        'form_feature_3_desc' => '您的所有信息将严格保密，不会泄露给第三方',
        'form_recommended_label' => '推荐',
        'js' => [
            'form_submitting_text' => '<i class="fa fa-spinner fa-spin mr-2"></i> 提交中...',
            'form_success_message' => '预约成功！我们的顾问将在24小时内与您联系。'
        ]
    ],
    // 样式类名配置
    'classes' => [
        'section_pretitle' => 'inline-block text-sm font-semibold text-blue-600 uppercase tracking-wider mb-2',
        'section_title' => 'text-3xl md:text-4xl font-bold text-gray-900 mb-4',
        'section_subtitle' => 'text-lg text-gray-600',
        'card_base' => 'p-8 rounded-xl transition-all duration-300 h-full',
        'card_modern' => 'bg-white shadow-md hover:shadow-xl hover:-translate-y-1',
        'card_classic' => 'border border-gray-200 hover:border-primary',
        'card_minimal' => '',
        'service_icon_container' => 'w-16 h-16 rounded-lg flex items-center justify-center mb-6 text-2xl transition-transform duration-500 group-hover:scale-110',
        'service_title' => 'text-xl font-semibold mb-3 text-gray-900 transition-colors duration-300',
        'service_description' => 'text-gray-600 mb-6',
        'service_feature_item' => 'flex items-center text-sm text-gray-700',
        'service_feature_icon' => 'fa fa-check mr-2',
        'service_case_count' => 'text-sm text-gray-500 mb-6',
        'service_case_icon' => 'fa fa-briefcase mr-1',
        'testimonial_container' => 'p-4 rounded-lg border border-gray-100',
        'testimonial_stars' => 'text-yellow-400 mb-2',
        'testimonial_text' => 'text-sm text-gray-700 italic mb-2',
        'testimonial_client' => 'text-xs text-gray-500',
        'process_step_container' => 'flex flex-col items-center text-center',
        'process_step_number' => 'w-16 h-16 rounded-full text-blue-600 flex items-center justify-center text-2xl font-bold mb-4 border-2 border-blue-100',
        'process_step_title' => 'text-xl font-semibold mb-2 text-gray-900',
        'process_step_description' => 'text-gray-600',
        'pricing_card' => '',
        'pricing_recommended_badge' => 'absolute top-0 right-0 text-blue-600 text-xs font-bold px-3 py-1 rounded-bl-lg border-2 border-blue-100',
        'pricing_title' => 'text-2xl font-bold text-gray-900 mb-1',
        'pricing_subtitle' => 'text-gray-600 mb-6',
        'pricing_price' => 'text-4xl font-bold text-gray-900',
        'pricing_period' => 'text-gray-600 ml-1',
        'pricing_feature_item' => 'flex items-start',
        'pricing_feature_icon' => 'fa fa-check text-green-500 mt-1 mr-3',
        'pricing_feature_text' => 'text-gray-700',
        'pricing_select_button' => 'block w-full py-3 px-4 font-medium rounded-lg transition-all duration-300 text-center',
        'pricing_select_button_default' => 'border-2 border-gray-800 text-gray-800 hover:bg-gray-50',
        'pricing_select_button_recommended' => 'border-2 border-blue-600 text-blue-600 hover:bg-blue-50',
        'pricing_custom_text' => 'text-gray-600',
        'pricing_contact_link' => 'text-blue-600 hover:underline font-medium',
        'expert_card' => 'border-2 border-gray-200 rounded-xl shadow-md overflow-hidden transition-transform duration-300 hover:scale-105',
        'expert_image_container' => 'h-64 border-2 border-gray-200 overflow-hidden',
        'expert_image' => 'w-full h-full object-cover',
        'expert_info' => 'p-6',
        'expert_name' => 'text-xl font-semibold text-gray-900 mb-1',
        'expert_title' => 'text-blue-600 mb-3',
        'expert_bio' => 'text-gray-600 text-sm mb-4',
        'expert_social_link' => 'text-gray-400 hover:text-blue-600 transition-colors',
        'form_container' => 'max-w-4xl mx-auto border-2 border-gray-200 rounded-2xl overflow-hidden',
        'form_info_panel' => 'p-8 lg:p-12 text-white',
        'form_info_title' => 'text-3xl font-bold mb-4',
        'form_info_subtitle' => 'mb-8 opacity-90',
        'form_feature' => 'flex items-start',
        'form_feature_icon_container' => 'flex-shrink-0 w-10 h-10 rounded-full bg-white/20 flex items-center justify-center',
        'form_feature_icon' => 'fa',
        'form_feature_content' => 'ml-4',
        'form_feature_title' => 'font-semibold mb-1',
        'form_feature_desc' => 'text-sm opacity-80',
        'form_panel' => 'p-8 lg:p-12 bg-white',
        'form_field_group' => '',
        'form_label' => 'block text-gray-700 font-medium mb-2',
        'form_required_mark' => 'text-red-500',
        'form_input' => 'w-full px-4 py-3 rounded-lg border border-gray-300 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all duration-300',
        'form_textarea' => 'w-full px-4 py-3 rounded-lg border border-gray-300 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all duration-300',
        'form_select' => 'w-full px-4 py-3 rounded-lg border border-gray-300 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all duration-300',
        'form_submit_button' => 'w-full py-3 px-4 bg-blue-600 hover:bg-blue-700 text-white font-medium rounded-lg transition-all duration-300 shadow hover:shadow-md focus:outline-none focus:ring-2 focus:ring-blue-500 focus:ring-offset-2'
    ]
];



// 合并配置（全局配置优先于默认配置）
$consultingConfig = array_merge($defaultConfig, $pageConfig['components'][$configKey] ?? []);

// 处理背景样式
$bgClass = "bg-{$consultingConfig['bg_color']}";

// 处理卡片样式
$cardStyles = [
    'modern' => $consultingConfig['classes']['card_base'] . ' ' . $consultingConfig['classes']['card_modern'],
    'classic' => $consultingConfig['classes']['card_base'] . ' ' . $consultingConfig['classes']['card_classic'],
    'minimal' => $consultingConfig['classes']['card_base'] . ' ' . $consultingConfig['classes']['card_minimal']
];
$cardClass = $cardStyles[$consultingConfig['card_style']] ?? $cardStyles['modern'];
?>

<!-- 咨询服务页面 -->
<section id="<?php echo htmlspecialchars($consultingConfig['section_id']); ?>" class="<?php echo $bgClass; ?> py-16">
    <div class="container mx-auto px-4 sm:px-6 lg:px-8">
        <!-- 区域标题 -->
        <div class="text-center max-w-3xl mx-auto mb-16">
            <?php if (!empty($consultingConfig['section_pretitle'])): ?>
                <span class="<?php echo htmlspecialchars($consultingConfig['classes']['section_pretitle']); ?>">
                    <?php echo htmlspecialchars($consultingConfig['section_pretitle']); ?>
                </span>
            <?php endif; ?>
            
            <h2 class="<?php echo htmlspecialchars($consultingConfig['classes']['section_title']); ?>">
                <?php echo htmlspecialchars($consultingConfig['section_title']); ?>
            </h2>
            
            <?php if (!empty($consultingConfig['section_subtitle'])): ?>
                <p class="<?php echo htmlspecialchars($consultingConfig['classes']['section_subtitle']); ?>">
                    <?php echo htmlspecialchars($consultingConfig['section_subtitle']); ?>
                </p>
            <?php endif; ?>
        </div>

        <!-- 咨询服务类型 -->
        <div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-8 mb-20">
            <?php foreach ($consultingConfig['services'] as $service): ?>
                <div class="<?php echo $cardClass; ?> group" data-service-card>
                    <!-- 图标容器 -->
                    <div class="<?php echo htmlspecialchars($consultingConfig['classes']['service_icon_container']); ?> bg-<?php echo $service['accent_color']; ?>/10 text-<?php echo $service['accent_color']; ?>">
                        <i class="fa <?php echo htmlspecialchars($service['icon']); ?>"></i>
                    </div>
                    
                    <!-- 服务信息 -->
                    <h3 class="<?php echo htmlspecialchars($consultingConfig['classes']['service_title']); ?> group-hover:text-<?php echo $service['accent_color']; ?>">
                        <?php echo htmlspecialchars($service['title']); ?>
                    </h3>
                    
                    <p class="<?php echo htmlspecialchars($consultingConfig['classes']['service_description']); ?>">
                        <?php echo htmlspecialchars($service['description']); ?>
                    </p>
                    
                    <!-- 服务特点 -->
                    <ul class="space-y-2 mb-6">
                        <?php foreach ($service['features'] as $feature): ?>
                            <li class="<?php echo htmlspecialchars($consultingConfig['classes']['service_feature_item']); ?>">
                                <i class="fa <?php echo htmlspecialchars($consultingConfig['classes']['service_feature_icon']); ?> text-<?php echo $service['accent_color']; ?>"></i>
                                <?php echo htmlspecialchars($feature); ?>
                            </li>
                        <?php endforeach; ?>
                    </ul>
                    
                    <!-- 案例数量 -->
                    <div class="<?php echo htmlspecialchars($consultingConfig['classes']['service_case_count']); ?>">
                        <i class="fa <?php echo htmlspecialchars($consultingConfig['classes']['service_case_icon']); ?>"></i>
                        <?php echo str_replace('{count}', $service['case_count'], htmlspecialchars($consultingConfig['texts']['case_count_label'])); ?>
                    </div>
                    
                    <!-- 客户评价 -->
                    <div class="<?php echo htmlspecialchars($consultingConfig['classes']['testimonial_container']); ?>">
                        <div class="<?php echo htmlspecialchars($consultingConfig['classes']['testimonial_stars']); ?>">
                            <i class="fa fa-star"></i>
                            <i class="fa fa-star"></i>
                            <i class="fa fa-star"></i>
                            <i class="fa fa-star"></i>
                            <i class="fa fa-star"></i>
                        </div>
                        <p class="<?php echo htmlspecialchars($consultingConfig['classes']['testimonial_text']); ?>">
                            "<?php echo htmlspecialchars($service['testimonial']); ?>"
                        </p>
                        <p class="<?php echo htmlspecialchars($consultingConfig['classes']['testimonial_client']); ?>">
                            <?php echo htmlspecialchars($service['client']); ?>
                        </p>
                    </div>
                </div>
            <?php endforeach; ?>
        </div>
        
        <!-- 咨询流程 -->
        <div class="max-w-5xl mx-auto mb-20">
            <div class="text-center mb-16">
                <h2 class="<?php echo htmlspecialchars($consultingConfig['classes']['section_title']); ?>">
                    <?php echo htmlspecialchars($consultingConfig['texts']['process_section_title']); ?>
                </h2>
                <p class="<?php echo htmlspecialchars($consultingConfig['classes']['section_subtitle']); ?> max-w-3xl mx-auto">
                    <?php echo htmlspecialchars($consultingConfig['texts']['process_section_subtitle']); ?>
                </p>
            </div>
            
            <div class="relative">
                <!-- 连接线 -->
                <div class="hidden md:block absolute top-1/2 left-0 right-0 h-1 bg-gray-200 -translate-y-1/2 z-0"></div>
                
                <div class="grid grid-cols-1 md:grid-cols-4 gap-8 relative z-10">
                    <?php foreach ($consultingConfig['process'] as $step): ?>
                        <div class="<?php echo htmlspecialchars($consultingConfig['classes']['process_step_container']); ?>">
                            <div class="<?php echo htmlspecialchars($consultingConfig['classes']['process_step_number']); ?>">
                                <?php echo $step['step']; ?>
                            </div>
                            <h3 class="<?php echo htmlspecialchars($consultingConfig['classes']['process_step_title']); ?>">
                                <?php echo htmlspecialchars($step['title']); ?>
                            </h3>
                            <p class="<?php echo htmlspecialchars($consultingConfig['classes']['process_step_description']); ?>">
                                <?php echo htmlspecialchars($step['description']); ?>
                            </p>
                        </div>
                    <?php endforeach; ?>
                </div>
            </div>
        </div>
        
        <!-- 咨询定价 -->
        <div class="max-w-5xl mx-auto mb-20">
            <div class="text-center mb-16">
                <h2 class="<?php echo htmlspecialchars($consultingConfig['classes']['section_title']); ?>">
                    <?php echo htmlspecialchars($consultingConfig['texts']['pricing_section_title']); ?>
                </h2>
                <p class="<?php echo htmlspecialchars($consultingConfig['classes']['section_subtitle']); ?> max-w-3xl mx-auto">
                    <?php echo htmlspecialchars($consultingConfig['texts']['pricing_section_subtitle']); ?>
                </p>
            </div>
            
            <div class="grid grid-cols-1 md:grid-cols-3 gap-8">
                <?php foreach ($consultingConfig['pricing'] as $package): ?>
                    <div class="<?php echo $cardClass; ?> relative <?php echo $package['recommended'] ? 'border-2 border-blue-500 scale-105 z-10' : ''; ?>">
                        <?php if ($package['recommended']): ?>
                            <div class="<?php echo htmlspecialchars($consultingConfig['classes']['pricing_recommended_badge']); ?>">
                                <?php echo htmlspecialchars($consultingConfig['texts']['form_recommended_label']); ?>
                            </div>
                        <?php endif; ?>
                        
                        <h3 class="<?php echo htmlspecialchars($consultingConfig['classes']['pricing_title']); ?>">
                            <?php echo htmlspecialchars($package['title']); ?>
                        </h3>
                        <p class="<?php echo htmlspecialchars($consultingConfig['classes']['pricing_subtitle']); ?>">
                            <?php echo htmlspecialchars($package['subtitle']); ?>
                        </p>
                        
                        <div class="mb-6">
                            <span class="<?php echo htmlspecialchars($consultingConfig['classes']['pricing_price']); ?>">¥<?php echo number_format($package['price']); ?></span>
                            <span class="<?php echo htmlspecialchars($consultingConfig['classes']['pricing_period']); ?>">/<?php echo htmlspecialchars($package['period']); ?></span>
                        </div>
                        
                        <ul class="space-y-3 mb-8">
                            <?php foreach ($package['features'] as $feature): ?>
                                <li class="<?php echo htmlspecialchars($consultingConfig['classes']['pricing_feature_item']); ?>">
                                    <i class="fa <?php echo htmlspecialchars($consultingConfig['classes']['pricing_feature_icon']); ?>"></i>
                                    <span class="<?php echo htmlspecialchars($consultingConfig['classes']['pricing_feature_text']); ?>">
                                        <?php echo htmlspecialchars($feature); ?>
                                    </span>
                                </li>
                            <?php endforeach; ?>
                        </ul>
                        
                        <a href="#consulting-form" class="<?php echo htmlspecialchars($consultingConfig['classes']['pricing_select_button']); ?> <?php echo $package['recommended'] ? htmlspecialchars($consultingConfig['classes']['pricing_select_button_recommended']) : htmlspecialchars($consultingConfig['classes']['pricing_select_button_default']); ?>">
                            <?php echo htmlspecialchars($consultingConfig['texts']['pricing_select_button']); ?>
                        </a>
                    </div>
                <?php endforeach; ?>
            </div>
            
            <div class="text-center mt-10">
                <p class="<?php echo htmlspecialchars($consultingConfig['classes']['pricing_custom_text']); ?>">
                    <?php echo htmlspecialchars($consultingConfig['texts']['pricing_custom_inquiry']); ?>
                    <a href="#consulting-form" class="<?php echo htmlspecialchars($consultingConfig['classes']['pricing_contact_link']); ?>">
                        <?php echo htmlspecialchars($consultingConfig['texts']['pricing_contact_link_text']); ?>
                    </a>
                    <?php echo htmlspecialchars($consultingConfig['texts']['pricing_contact_suffix']); ?>
                </p>
            </div>
        </div>
        
        <!-- 咨询专家团队 -->
        <div class="max-w-5xl mx-auto mb-20">
            <div class="text-center mb-16">
                <h2 class="<?php echo htmlspecialchars($consultingConfig['classes']['section_title']); ?>">
                    <?php echo htmlspecialchars($consultingConfig['texts']['experts_section_title']); ?>
                </h2>
                <p class="<?php echo htmlspecialchars($consultingConfig['classes']['section_subtitle']); ?> max-w-3xl mx-auto">
                    <?php echo htmlspecialchars($consultingConfig['texts']['experts_section_subtitle']); ?>
                </p>
            </div>
            
            <div class="grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-8">
                <!-- 专家1 -->
                <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_card']); ?>">
                    <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_image_container']); ?>">
                        <img src="https://picsum.photos/seed/consultant1/400/600" alt="张顾问，战略咨询总监" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_image']); ?>">
                    </div>
                    <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_info']); ?>">
                        <h3 class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_name']); ?>">张顾问</h3>
                        <p class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_title']); ?>">战略咨询总监</p>
                        <p class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_bio']); ?>">前麦肯锡高级顾问，15年战略规划经验，服务过50+上市公司</p>
                        <div class="flex space-x-3">
                            <a href="#" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_social_link']); ?>">
                                <i class="fa fa-linkedin"></i>
                            </a>
                            <a href="#" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_social_link']); ?>">
                                <i class="fa fa-twitter"></i>
                            </a>
                        </div>
                    </div>
                </div>
                
                <!-- 专家2 -->
                <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_card']); ?>">
                    <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_image_container']); ?>">
                        <img src="https://picsum.photos/seed/consultant2/400/600" alt="李顾问，运营效率专家" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_image']); ?>">
                    </div>
                    <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_info']); ?>">
                        <h3 class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_name']); ?>">李顾问</h3>
                        <p class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_title']); ?>">运营效率专家</p>
                        <p class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_bio']); ?>">精益管理大师，12年运营优化经验，帮助企业平均降低成本20%</p>
                        <div class="flex space-x-3">
                            <a href="#" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_social_link']); ?>">
                                <i class="fa fa-linkedin"></i>
                            </a>
                            <a href="#" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_social_link']); ?>">
                                <i class="fa fa-twitter"></i>
                            </a>
                        </div>
                    </div>
                </div>
                
                <!-- 专家3 -->
                <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_card']); ?>">
                    <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_image_container']); ?>">
                        <img src="https://picsum.photos/seed/consultant3/400/600" alt="王顾问，数字化转型专家" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_image']); ?>">
                    </div>
                    <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_info']); ?>">
                        <h3 class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_name']); ?>">王顾问</h3>
                        <p class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_title']); ?>">数字化转型专家</p>
                        <p class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_bio']); ?>">前IBM数字化战略顾问，帮助30+企业成功实现数字化转型</p>
                        <div class="flex space-x-3">
                            <a href="#" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_social_link']); ?>">
                                <i class="fa fa-linkedin"></i>
                            </a>
                            <a href="#" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_social_link']); ?>">
                                <i class="fa fa-twitter"></i>
                            </a>
                        </div>
                    </div>
                </div>
                
                <!-- 专家4 -->
                <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_card']); ?>">
                    <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_image_container']); ?>">
                        <img src="https://picsum.photos/seed/consultant4/400/600" alt="赵顾问，人力资源专家" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_image']); ?>">
                    </div>
                    <div class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_info']); ?>">
                        <h3 class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_name']); ?>">赵顾问</h3>
                        <p class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_title']); ?>">人力资源专家</p>
                        <p class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_bio']); ?>">10年+人力资源咨询经验，擅长组织发展与人才管理体系建设</p>
                        <div class="flex space-x-3">
                            <a href="#" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_social_link']); ?>">
                                <i class="fa fa-linkedin"></i>
                            </a>
                            <a href="#" class="<?php echo htmlspecialchars($consultingConfig['classes']['expert_social_link']); ?>">
                                <i class="fa fa-twitter"></i>
                            </a>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        
        <!-- 咨询预约表单 -->
        <div id="consulting-form" class="<?php echo htmlspecialchars($consultingConfig['classes']['form_container']); ?>">
            <div class="grid grid-cols-1 lg:grid-cols-2">
                <!-- 表单信息 -->
                <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_info_panel']); ?> bg-gradient-to-br from-blue-600 to-indigo-700">
                    <h2 class="<?php echo htmlspecialchars($consultingConfig['classes']['form_info_title']); ?>">
                        <?php echo htmlspecialchars($consultingConfig['cta']['title']); ?>
                    </h2>
                    <p class="<?php echo htmlspecialchars($consultingConfig['classes']['form_info_subtitle']); ?>">
                        <?php echo htmlspecialchars($consultingConfig['cta']['subtitle']); ?>
                    </p>
                    
                    <div class="space-y-6">
                        <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature']); ?>">
                            <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_icon_container']); ?>">
                                <i class="fa <?php echo htmlspecialchars($consultingConfig['classes']['form_feature_icon']); ?> fa-check"></i>
                            </div>
                            <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_content']); ?>">
                                <h4 class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_title']); ?>">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_feature_1_title']); ?>
                                </h4>
                                <p class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_desc']); ?>">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_feature_1_desc']); ?>
                                </p>
                            </div>
                        </div>
                        
                        <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature']); ?>">
                            <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_icon_container']); ?>">
                                <i class="fa <?php echo htmlspecialchars($consultingConfig['classes']['form_feature_icon']); ?> fa-clock-o"></i>
                            </div>
                            <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_content']); ?>">
                                <h4 class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_title']); ?>">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_feature_2_title']); ?>
                                </h4>
                                <p class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_desc']); ?>">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_feature_2_desc']); ?>
                                </p>
                            </div>
                        </div>
                        
                        <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature']); ?>">
                            <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_icon_container']); ?>">
                                <i class="fa <?php echo htmlspecialchars($consultingConfig['classes']['form_feature_icon']); ?> fa-lock"></i>
                            </div>
                            <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_content']); ?>">
                                <h4 class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_title']); ?>">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_feature_3_title']); ?>
                                </h4>
                                <p class="<?php echo htmlspecialchars($consultingConfig['classes']['form_feature_desc']); ?>">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_feature_3_desc']); ?>
                                </p>
                            </div>
                        </div>
                    </div>
                </div>
                
                <!-- 表单 -->
                <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_panel']); ?>">
                    <form 
                        action="<?php echo htmlspecialchars($consultingConfig['cta']['form_action']); ?>" 
                        method="post"
                        class="space-y-6"
                        id="consultForm"
                    >
                        <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_field_group']); ?>">
                            <label for="company" class="<?php echo htmlspecialchars($consultingConfig['classes']['form_label']); ?>">
                                公司名称 
                                <span class="<?php echo htmlspecialchars($consultingConfig['classes']['form_required_mark']); ?>">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_required_mark']); ?>
                                </span>
                            </label>
                            <input 
                                type="text" 
                                id="company" 
                                name="company" 
                                required
                                class="<?php echo htmlspecialchars($consultingConfig['classes']['form_input']); ?>"
                                placeholder="<?php echo htmlspecialchars($consultingConfig['texts']['form_company_placeholder']); ?>"
                            >
                        </div>
                        
                        <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_field_group']); ?>">
                            <label for="contact_name" class="<?php echo htmlspecialchars($consultingConfig['classes']['form_label']); ?>">
                                联系人姓名 
                                <span class="<?php echo htmlspecialchars($consultingConfig['classes']['form_required_mark']); ?>">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_required_mark']); ?>
                                </span>
                            </label>
                            <input 
                                type="text" 
                                id="contact_name" 
                                name="contact_name" 
                                required
                                class="<?php echo htmlspecialchars($consultingConfig['classes']['form_input']); ?>"
                                placeholder="<?php echo htmlspecialchars($consultingConfig['texts']['form_contact_name_placeholder']); ?>"
                            >
                        </div>
                        
                        <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_field_group']); ?>">
                            <label for="phone" class="<?php echo htmlspecialchars($consultingConfig['classes']['form_label']); ?>">
                                联系电话 
                                <span class="<?php echo htmlspecialchars($consultingConfig['classes']['form_required_mark']); ?>">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_required_mark']); ?>
                                </span>
                            </label>
                            <input 
                                type="tel" 
                                id="phone" 
                                name="phone" 
                                required
                                class="<?php echo htmlspecialchars($consultingConfig['classes']['form_input']); ?>"
                                placeholder="<?php echo htmlspecialchars($consultingConfig['texts']['form_phone_placeholder']); ?>"
                            >
                        </div>
                        
                        <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_field_group']); ?>">
                            <label for="email" class="<?php echo htmlspecialchars($consultingConfig['classes']['form_label']); ?>">
                                电子邮箱 
                                <span class="<?php echo htmlspecialchars($consultingConfig['classes']['form_required_mark']); ?>">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_required_mark']); ?>
                                </span>
                            </label>
                            <input 
                                type="email" 
                                id="email" 
                                name="email" 
                                required
                                class="<?php echo htmlspecialchars($consultingConfig['classes']['form_input']); ?>"
                                placeholder="<?php echo htmlspecialchars($consultingConfig['texts']['form_email_placeholder']); ?>"
                            >
                        </div>
                        
                        <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_field_group']); ?>">
                            <label for="service_type" class="<?php echo htmlspecialchars($consultingConfig['classes']['form_label']); ?>">
                                感兴趣的服务 
                                <span class="<?php echo htmlspecialchars($consultingConfig['classes']['form_required_mark']); ?>">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_required_mark']); ?>
                                </span>
                            </label>
                            <select 
                                id="service_type" 
                                name="service_type" 
                                required
                                class="<?php echo htmlspecialchars($consultingConfig['classes']['form_select']); ?>"
                            >
                                <option value="">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_service_type_default']); ?>
                                </option>
                                <?php foreach ($consultingConfig['services'] as $service): ?>
                                    <option value="<?php echo $service['id']; ?>"><?php echo htmlspecialchars($service['title']); ?></option>
                                <?php endforeach; ?>
                                <option value="multiple">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_service_type_multiple']); ?>
                                </option>
                                <option value="other">
                                    <?php echo htmlspecialchars($consultingConfig['texts']['form_service_type_other']); ?>
                                </option>
                            </select>
                        </div>
                        
                        <div class="<?php echo htmlspecialchars($consultingConfig['classes']['form_field_group']); ?>">
                            <label for="message" class="<?php echo htmlspecialchars($consultingConfig['classes']['form_label']); ?>">
                                咨询需求描述
                            </label>
                            <textarea 
                                id="message" 
                                name="message" 
                                rows="4"
                                class="<?php echo htmlspecialchars($consultingConfig['classes']['form_textarea']); ?>"
                                placeholder="<?php echo htmlspecialchars($consultingConfig['texts']['form_message_placeholder']); ?>"
                            ></textarea>
                        </div>
                        
                        <div class="pt-2">
                            <button 
                                type="submit" 
                                class="<?php echo htmlspecialchars($consultingConfig['classes']['form_submit_button']); ?>"
                            >
                                <?php echo htmlspecialchars($consultingConfig['cta']['button_text']); ?>
                            </button>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</section>

<!-- 咨询服务交互脚本 -->
<script>
document.addEventListener('DOMContentLoaded', function() {
    // 从PHP配置获取所有数据
    const config = <?php echo json_encode($consultingConfig); ?>;
    
    // 服务卡片动画
    const serviceCards = document.querySelectorAll('[data-service-card]');
    const observer = new IntersectionObserver((entries) => {
        entries.forEach(entry => {
            if (entry.isIntersecting) {
                entry.target.style.opacity = '1';
                entry.target.style.transform = 'translateY(0)';
                observer.unobserve(entry.target);
            }
        });
    }, { threshold: 0.1 });
    
    serviceCards.forEach((card, index) => {
        card.style.opacity = '0';
        card.style.transform = 'translateY(30px)';
        card.style.transition = `opacity 0.5s ease ${index * 0.1}s, transform 0.5s ease ${index * 0.1}s`;
        observer.observe(card);
    });
    
    // 流程步骤动画
    const processSteps = document.querySelectorAll('.<?php echo htmlspecialchars($consultingConfig['classes']['process_step_container']); ?>');
    const processObserver = new IntersectionObserver((entries) => {
        entries.forEach(entry => {
            if (entry.isIntersecting) {
                entry.target.style.opacity = '1';
                entry.target.style.transform = 'translateY(0)';
                processObserver.unobserve(entry.target);
            }
        });
    }, { threshold: 0.2 });
    
    processSteps.forEach((step, index) => {
        step.style.opacity = '0';
        step.style.transform = 'translateY(20px)';
        step.style.transition = `opacity 0.5s ease ${index * 0.15}s, transform 0.5s ease ${index * 0.15}s`;
        processObserver.observe(step);
    });
    
    // 表单提交处理
    const consultForm = document.getElementById('consultForm');
    if (consultForm) {
        consultForm.addEventListener('submit', function(e) {
            e.preventDefault();
            
            // 在实际项目中，这里会有AJAX提交表单的逻辑
            const submitButton = this.querySelector('button[type="submit"]');
            const originalText = submitButton.innerHTML;
            
            // 显示加载状态，使用配置中的文本
            submitButton.disabled = true;
            submitButton.innerHTML = config.texts.js.form_submitting_text;
            
            // 模拟表单提交
            setTimeout(() => {
                // 显示成功消息（使用配置中的文本）
                alert(config.texts.js.form_success_message);
                
                // 重置表单和按钮
                this.reset();
                submitButton.disabled = false;
                submitButton.innerHTML = originalText;
            }, 1500);
        });
    }
    
    // 平滑滚动
    document.querySelectorAll('a[href^="#"]').forEach(anchor => {
        anchor.addEventListener('click', function(e) {
            e.preventDefault();
            
            const targetId = this.getAttribute('href');
            const targetElement = document.querySelector(targetId);
            
            if (targetElement) {
                targetElement.scrollIntoView({
                    behavior: 'smooth',
                    block: 'start'
                });
            }
        });
    });
});
</script>
    